Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unity 2020.3.30f1 Exporting a prefab from Project will result in missing animations. #745

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

ArminRoiderKubat
Copy link

gameObject.activeInHierarchy will return false if the GameObject is a prefab and not instantiated in the scene.

…check. gameObject.activeInHierarchy will return false if the GameObject is a prefab and not instantiated in the scene
@CLAassistant
Copy link

CLAassistant commented Jun 28, 2024

CLA assistant check
All committers have signed the CLA.

@pfcDorn
Copy link
Contributor

pfcDorn commented Sep 4, 2024

Seems to work with Unity 2021.3.+ without these changes.
@hybridherbst, whats your opinion? it would only benefit the compatibility support for 2020.3

@hybridherbst
Copy link
Collaborator

I remember we had to do changes in the past to make that usecase work (exporting from Project), despite activeInHierarchy being false.

@ArminRoiderKubat could you please provide reproduction steps and a reproduction .unitypackage? Thanks

@ArminRoiderKubat
Copy link
Author

Here is the package and the exported glTF files.
PR745.zip

CubeScene.gltf will contain animations.
CubeProject.gltf has no animations.
Both are exported from the same prefab. The first was exported by selecting the Prefab instance in the Hierarchy window in a open scene. The other by selecting it in the Project tab.

Steps:

  • Open the SampleScene, select the CubeScene GameObject and "Export selected as glTF".
  • Select the Prefab CubeProject and "Export selected as glTF".
  • Compare both files. The second export does not contain animations.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants